<extend name="Public:base" />
<block name="header" >
    <!--<span class="action-span"><a href="#">商品售卖列表</a></span>-->
    <span class="action-span1"><a href="#">武汉同兴一站办企业服务有限公司 管理中心</a></span>
    <span id="search_id" class="action-span1"> - 商品售卖列表 </span>
    <div style="clear:both"></div>
</block>

<block name="body">
    <form action="" name="searchForm" method="post">
        <img src="__PUBLIC_ADMIN__/Images/icon_search.gif" width="26" height="22" border="0" alt="search" />
        <!-- 分类 -->
        <select name="type_id">

            <option  name="type_id" value="0">|&#45;&#45;请选择</option>
            <foreach name="type" item="vo" key="k">
                <option  name="type_id" id="kk{$k}" value="{$k}">|&#45;&#45;{$vo}</option>
            </foreach>

        </select>
    关键字 <input type="text" name="goods_name" size="15" id="key" value=""/>
    排序&nbsp;&nbsp;&nbsp;&nbsp;
        按id<input type="radio" name="pai" checked="checked" id="price_id" value="price_id">
        按价格<input type="radio" name="pai" id='price' value="price">
    <input type="submit" value="搜索 " class="button" />
    </form>
<!-- 商品列表 -->

<div class="list-div" id="listDiv">
    <table cellpadding="3" cellspacing="1">
        <tr>
            <th>编号</th>
            <th>商品</th>
            <th>地区</th>
            <th>标准定价</th>
            <th>初始价格</th>
            <th>VIP折扣</th>
            <th>规格</th>
            <th>操作</th>
        </tr>
        <volist name="data" id="vo" key="sort">
        <tr>
            <td align="center">{$vo.price_id}</td>
            <td align="center" width="5%"><span>{$vo.goods_ids}</span></td>
            <td align="center"><span>{$vo.region_id}</span></td>
            <td align="center"><span>{$vo.normals}</span></td>
            <if condition="$vo['normal']==0">
                <td align="center"><span>面议</span></td>
                <else/>
                <td align="center"><span>{$vo.price}</span></td>
            </if>

            <td align="center" width="30%"><span>{$vo.vip_discounts}</span></td>
            <td align="center" width="35%"><span>{$vo.specs}</span></td>
            <td align="center">
            <!--<a href="{:U('goods_priceedit','id='.$vo['price_id'])}" >编辑</a>-->
            <a href="{:U('goods_pricedels','id='.$vo['price_id'])}" >删除</a>
            </td>
        </tr>
        </volist>
    </table>

    <!-- 分页开始 -->
    <table id="page-table" cellspacing="0">
        <tr>
            <td align="center" nowrap="true">
              {$page}
            </td>
        </tr>
    </table>
    <input type="hidden" id="type_id" value="{$type_id}">
    <input type="hidden" id="key_world" value="{$key_world}">
    <input type="hidden" id="pai" value="{$pai}">
<!-- 分页结束 -->
</div>
    <script type="text/javascript">
        var a=document.getElementById("type_id").value;
        var b=document.getElementById("key_world").value;
        var c=document.getElementById("pai").value;
        if(a==2){
            document.getElementById("kk2").setAttribute("selected",'selected');
            document.getElementById("key").setAttribute("value",b);
            if(c=='price'){
                document.getElementById("price_id").removeAttribute("checked");
                document.getElementById("price").setAttribute("checked",'checked');
            }else{
                document.getElementById("price").removeAttribute("checked");
                document.getElementById("price_id").setAttribute("checked",'checked');
            }
        }
    </script>
</block>